package action;

import infrastructure.IDossier;

import java.util.ArrayList;
import java.util.List;

import mappers.DossierMapper;

import com.opensymphony.xwork2.ActionSupport;

public class VisualiserDossiersAction extends ActionSupport {
	private static final long serialVersionUID = 1L;
	private List<IDossier> dossiers = new ArrayList<IDossier>();
	private DossierMapper dossierDAO;

	public void setDossierDAO(DossierMapper dossierDAO) {
		this.dossierDAO = dossierDAO;
	}
	public List<IDossier> getDossiers() {
		return dossiers;
	}

	public void setDossiers(List<IDossier> dossiers) {
		this.dossiers = dossiers;
	}
	
	public String visualiserDossiers() {
		setDossiers(dossierDAO.getDossiers());
		return SUCCESS;
	}
}
